import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;

import javax.imageio.ImageIO;


public class umwandlung {

public static void saveToPng(BufferedImage i, String filename){
	try {
		File outputfile = new File(filename);
		ImageIO.write(i, "png", outputfile);
	} catch (IOException e) {
		e.printStackTrace();
	}
}
	
public static void saveToJpg(BufferedImage i, String filename){
	try {
		File outputfile = new File(filename);
		ImageIO.write(i, "jpg", outputfile);
	} catch (IOException e) {
		e.printStackTrace();
	}
}
		
	
	


}
